const isWeChatBrowser = () => {
	let ua = window.navigator.userAgent.toLowerCase()
	if (ua.match(/MicroMessenger/i) == 'micromessenger') {
		return true;
	}
	return false;
}

const isAliBrowser = () => {
	let ua = window.navigator.userAgent.toLowerCase()
	if (ua.match(/alipayclient/i) == 'alipayclient') {
		return true;
	}
	return false;
}

const isAndroid = /Android/.test(navigator.userAgent);

const isIOS = /iPad|iPhone|iPod/.test(navigator.userAgent);

export default {
	isWeChatBrowser,
	isAliBrowser,
	isAndroid,
	isIOS,
}
